package com.jerry.seckill.dto;

/** 
  * @describe 暴露秒杀地址DTO  
  * exposer 汉语意思 曝光
  */ 
public class Exposer { 
	
	// 是否开启秒杀 
	private boolean exposed; 
	// 一种加密措施 
	private String md5; 
	// 商品库存id
	private long seckillId; 
	// 系统当前时间(毫秒) 
	private long now; 
	// 开启时间 
	private long start; 
	// 结束时间 
	private long end;
	
	public Exposer(boolean exposed, long seckillId) {
		super();
		this.exposed = exposed;
		this.seckillId = seckillId;
	}
	
	public Exposer(boolean exposed, String md5, long seckillId) {
		super();
		this.exposed = exposed;
		this.md5 = md5;
		this.seckillId = seckillId;
	}
	
	public Exposer(long now, long start, long end) {
		super();
		this.now = now;
		this.start = start;
		this.end = end;
	}

	public Exposer(boolean exposed, long seckillId, long now, long start, long end) {
		super();
		this.exposed = exposed;
		this.seckillId = seckillId;
		this.now = now;
		this.start = start;
		this.end = end;
	}

	public boolean isExposed() {
		return exposed;
	}
	public void setExposed(boolean exposed) {
		this.exposed = exposed;
	}
	public String getMd5() {
		return md5;
	}
	public void setMd5(String md5) {
		this.md5 = md5;
	}
	public long getSeckillId() {
		return seckillId;
	}
	public void setSeckillId(long seckillId) {
		this.seckillId = seckillId;
	}
	public long getNow() {
		return now;
	}
	public void setNow(long now) {
		this.now = now;
	}
	public long getStart() {
		return start;
	}
	public void setStart(long start) {
		this.start = start;
	}
	public long getEnd() {
		return end;
	}
	public void setEnd(long end) {
		this.end = end;
	} 

	@Override
	public String toString() {
		StringBuffer sb = new StringBuffer();
		sb.append("seckillId="+seckillId);
		sb.append(",   ");
		sb.append("exposed="+exposed);
		sb.append(",   ");
		sb.append("md5="+md5);
		sb.append(",   ");
		sb.append("now="+now);
		sb.append(",   ");
		sb.append("start="+start);
		sb.append(",   ");
		sb.append("end="+end);
		return sb.toString();
	}
	
}
